/*
 * Physx.cpp
 *
 *  Created on: Jan 25, 2012
 *      Author: The Almighty Eric
 */

#include "Physx.h"

Physx::Physx()
{
	dx = 0;
	dy = 0;
	dymax = 0;
}

Physx::Physx(float idx, float idy, float idymax)
{
	dx = dx;
	dy = dy;
	dymax = dymax;
}

void Physx::Updatedy(Uint32 ticks)
{
	if(dy < dymax)
	{
		dy += dy * (1000*(ticks/1000.f));
	}
}

void Physx::setdy(float idy)
{
	dy = idy;
}

float Physx::Updatex(float x, Uint32 ticks)
{
	x += dx * ticks/1000.f;
	return x;
}

float Physx::Updatey(float y, Uint32 ticks)
{
	y += dy * ticks/1000.f;
	return y;
}
